package com.bosc.automationui.util;

import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;

public class DependencyParseUtil {

    public static void main(String[] args) {

        HashMap<String, String> dependencyMapping = new HashMap<>();
        List<List> chains = new ArrayList<>();
        List<String> head = new ArrayList<>();
        List<String> chain = new ArrayList<>();

        dependencyMapping.put("C", "B");
        dependencyMapping.put("B", "A");
        dependencyMapping.put("A", null);

        dependencyMapping.put("X", "Y");
        dependencyMapping.put("Y", null);

        for(String dependencyKey: dependencyMapping.keySet()) {
            if (dependencyMapping.get(dependencyKey) == null) {
                System.out.println(dependencyKey);
                head.add(dependencyKey);
            }
        }


        for(String h: head) {

        }


    }
}
